<div id="main-content">
    <div id="main" class="main">
       <div class="user-hd">
            <h2>财务管理>>结算管理>>结算详情
            <a href="{:U('/Admin/Bill/index')}" class="gray-btn" style="position: absolute;  bottom: 16px; right: 25px;">返回</a>
            </h2>
       </div>
       <div class="spin-cont">
            <div class="user_zl">
                <dl class="clearfix">
                    <dt>结算周期：</dt>
                    <dd>{$bill.start_time|date='Y-m-d', ###} - {$bill.end_time|date='Y-m-d', ###}</dd>
                </dl>
                <dl class="clearfix">
                    <dt>结算单号：</dt>
                    <dd>{$bill.bill_sn}</dd>
                    <dt>结算时间：</dt>
                    <dd>{$bill.ctime|date='Y-m-d', ###}</dd>
                    <dt>结算影院：</dt>
                    <dd>{$bill.host_name|getCinemaNameByhost}</dd>
                </dl>
                <dl class="clearfix">
                    <dt>订单总支付金额：</dt>
                    <dd>{$bill.pay_money|numFormat=2}元 = {$bill.money_ali}(支付宝支付) + {$bill.money_weixin}(微信支付)</dd>
                </dl>
                <dl class="clearfix">
                    <dt>支付手续费：</dt>
                    <dd>{$bill.fee_money|numFormat=2}元 = {$bill.refund_ali}(支付宝手续费) + {$bill.refund_weixin}(微信手续费)</dd>
                </dl>
                <dl class="clearfix">
                    <dt>订单退款：</dt>
                    <dd>{$bill.refund_money|numFormat=2}元 = {$bill.refund_ali}(支付宝退款) + {$bill.refund_weixin}(微信退款)</dd>
                </dl>
                <dl class="clearfix" style="font-weight:bold;color:#dc5858;">
                    <dt>商家应结小计：</dt>
                    <dd>{$bill.money_total}元</dd>
                </dl>
            </div>
            
            <a class="tab_menu <neq name='search.type' value='weixin'>active</neq>" href="{:U('/Admin/Bill/detail', array('bill_sn'=>$bill['bill_sn']))}">支付宝支付订单</a><a class="tab_menu <eq name='search.type' value='weixin'>active</eq>"  href="{:U('/Admin/Bill/detail', array('bill_sn'=>$bill['bill_sn'], 'type'=>'weixin'))}">微信支付订单</a>
            <table class="tab">
                <tbody>
                    <tr>
                        <td colspan="6" class="search">
                            <div class="clearfix searchspin">
                                <dl>
                                    <dt>筛选条件:</dt>
                                    <dd class="filter-a">
                                        <form method="get" action="{:U()}">下单时间:
                                            <input type="hidden" name="bill_sn" value="{$bill.bill_sn}">
                                            <input type="hidden" name="type" value="{$search.type}">
                                            <input type="text" id="date_start" name="date_start" value="{$search.date_start}" class="w88" <literal> onfocus="WdatePicker({maxDate:'#F{$dp.$D(\'date_end\')||\'%y-%M-%d\'}'})" </literal> placeholder="开始日期" /> 至
                                            <input type="text" id="date_end" name="date_end" value="{$search.date_end}" class="w88 mr13" <literal> onfocus="WdatePicker({minDate:'#F{$dp.$D(\'date_start\')}', maxDate:'%y-%M-%d'})" </literal> placeholder="结束日期" />
                                            <input name="order_sn" class="w135 mr13" type="search" placeholder="请输入订单号码" value="{$search.order_sn}" >
                                            <span>订单状态:</span>
                                            <select name="status">
                                                <option value="0">全部</option>
                                                <option value="1" <eq name="search.status" value="1">selected</eq>>已完成</option>
                                                <option value="2" <eq name="search.status" value="2">selected</eq>>退款</option>
                                            </select>
                                            
                                            <a class="sblue-btn" href="{:U('/Admin/Bill/detail', array('bill_sn'=>$bill['bill_sn'], 'type'=>$search['type']))}">清空 </a>
                                            <button class="sblue-btn" onclick="this.form.submit();">搜索</button>
                                        </form>
                                    </dd>
                                </dl>
                            </div>
                        </td>
                    </tr>
                    <tr>
                        <th>订单号</th>
                        <th>下单时间</th>
                        <th>支付金额</th>
                        <th>支付方式</th>
                        <th>订单状态</th>
                        <th>操作</th>
                    </tr>
                    <volist name="data_list" id="vo">
                        <tr>
                            <td>{$vo.net_order_sn}</td>
                            <td>{$vo.ctime|date='Y-m-d H:i', ###}</td>
                            <td>{$vo.money}</td>
                            <td>{$vo.method|getPayMethod}</td>
                            <td><eq name='vo.is_refund' value='1'>退款<else />已完成</eq></td>
                            <td><a href="{:U('Admin/Order/detail', array('order_sn' =>$vo['net_order_sn']))}">订单详情 </a></td>
                        </tr>
                    </volist>
                    <empty name="data_list">
                        <tr>
                            <td colspan="6">无信息...</td>
                        </tr>
                    </empty>
                </tbody>
            </table>
             <div class="spin-upbox clearfix page txt-center">
                {$pager}
            </div>
        </div>
    </div>
</div>